package com.woniu.user.service.impl;

import com.woniu.user.entity.Advice;
import com.woniu.user.mapper.AdviceMapper;
import com.woniu.user.service.AdviceService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author author
 * @create 2021/5/19
 * <p>
 * 建议接口实现类
 */
@Service
public class AdviceServiceImpl implements AdviceService {

    @Autowired
    AdviceMapper adviceMapper;

    @Override
    public boolean addAdvice(Advice advice) {
        return adviceMapper.addAdvice(advice);
    }

    @Override
    public boolean updateStatusById(Integer id) {
        return adviceMapper.updateStatusById(id);
    }

    @Override
    public boolean addReply(String reply) {
        return adviceMapper.addReply(reply);
    }

    @Override
    public List<Advice> selectAllAdvice() {
        return adviceMapper.selectAllAdvice();
    }
}
